home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
BBS Toolkit
/
BBS Toolkit.iso
/
doors_2
/
twview91.zip
/
EXAMINE.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1992-03-11
|
3KB
|
121 lines
program InfoViewer;
{ written mid december 1990 to date by woody }
{ dos version }
uses
DOS, CRT, graph;
{$I headers.inc}
var {globals}
space : TheVoid;
BBSname : string;
g : text;
BaseChanged,
quit : boolean;
distances : distanceArray;
verbose : boolean; { text output verbose or terse codes }
mono : boolean; { for monochrome graphics in printouts }
svga : boolean; { special for autodetect. Not yet implemented.}
{$I QUEUE.INC }
{$I status.inc }
{$I misc.inc }
{$I distance.inc }
{$I viewdos.inc }
{$I textdisp.inc }
{$I portdisp.inc }
{$I notestuf.inc }
{$I basepath.inc }
{$I pathstuf.inc }
{$I teleport.inc }
{$I GSDATA.INC }
{$I busy.inc }
{$I netchang.inc }
{$I config.inc }
procedure menu;
const
left = 35;
right = 40;
begin
writeln('Choose one of ');
write('<A>dd note':left);
writeln('<B>usiest ports':right);
write('<C>lassify ports': left);
writeln('<D>elete note':right);
write('Closest place to buy <F>ighters':left);
writeln('Note <I>nformation':right);
write('<L>ength & path between two sectors':left);
writeln('<M>isc config options':right);
write('<N>earest port':left);
writeln('<P>aired ports':right);
write('<Q>uit':left);
writeln('Nearest <S>ectors':right);
write('<T>ranswarp menu':left);
writeln('Nearest <U>nexplored sectors':right);
write('<V>iew space in graphic format':left);
writeln('<W>here is nearest fighter cloud':right);
writeln('Net change <X>' : left);
writeln;
end; {menu}
function choice : char;
var
ch : char;
begin
write('(', BBSName, ') [A, B, C, D, F, I, L, M, N, P, Q, S, T, U, V, W, X] Your choice? ');
readln( ch );
choice := upcase( ch );
end;
begin
Textcolor( LightGray );
clrScr;
writeln('Tradewars Data Base Viewer: ', version);
writeln( author );
writeln( source );
writeln;
Quit := false;
BaseChanged := false;
SVGA := false;
verbose := true;
Mono := false;
InitSpace( Space );
if paramcount > 0 then
BBSName := paramstr( 1 )
else
BBSName := '';
GetData( Space, BBSName );
menu;
repeat
case choice of
'A' : AddNote( BaseChanged );
'B' : BusyPorts;
'C' : NearestStuff( SpecPort, GetPortType );
'D' : RemoveNote( BaseChanged );
'F' : NearestFighters;
'I' : NearestStuff( NoteOnly, 0 );
'L' : PathLength;
'M' : ConfigStuff;
'N' : NearestStuff( PortOnly, 0 );
'P' : pairPort;
'Q' : quit := true;
'S' : NearestStuff( any, 0);
'T' : TransWarpMenu( BaseChanged );
'U' : NearestStuff( UnExpOnly, 0);
'V' : view;
'W' : NearestStuff( FighterOnly, 0 );
'X' : HighChange;
else
menu;
end; {case}
until quit;
if BaseChanged then
begin
assign( g, GetNewFileName('File name for new data base? ',
bbsname+'.dat') );
rewrite( g );
saveData( g, space );
end;
end.